package izzat.fit.training.remote;

import izzat.fit.training.entity.ActionSet;
import izzat.fit.training.entity.Plan;
import izzat.fit.training.entity.RequestEntity;
import izzat.fit.training.entity.ResponseEntity;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.swing.*;

/**
 * @ClassName: DBRemote
 * @Description:
 * @Author: Izzat
 * @Date: 2020-01-16 14:57
 * @Version: v1.0
 */
@FeignClient(name= "db-service")
@RequestMapping(value = "db-service/training")
public interface  DBRemote {
    @RequestMapping(value = "test")
    public String hello();

    @RequestMapping(value = "allPlan")
    public ResponseEntity allPlan();

    @RequestMapping(value = "findPlanById")
    public ResponseEntity findPlanById(int id);

    @RequestMapping(value = "findPlanByCreator")
    public ResponseEntity findPlanByCreator(RequestEntity requestEntity);

    @RequestMapping(value = "deletePlanById")
    public ResponseEntity deletePlanById(int[] id);

    @RequestMapping(value = "findActionSetByPlanId")
    public ResponseEntity findActionSetByPlanId(int id);

    @RequestMapping(value = "addPlan")
    public ResponseEntity addPlan(RequestEntity requestEntity);

}

